<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<META HTTP-EQUIV="Pragma" CONTENT="no-cache"> 
	<META HTTP-EQUIV="Cache-Control" CONTENT="no-cache"> 
	<META HTTP-EQUIV="Expires" CONTENT="0">
	<title>提取申请</title>
	<meta name="renderer" content="webkit">
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
	<meta name="apple-mobile-web-app-status-bar-style" content="black">
	<meta name="apple-mobile-web-app-capable" content="yes">
	<meta name="format-detection" content="telephone=no">
	<link rel="stylesheet" href="../../layui/css/layui.css" media="all" />
	<link rel="stylesheet" href="../../css/font_eolqem241z66flxr.css" media="all" />
	<link rel="stylesheet" href="../../css/news.css" media="all" />
	<script src="../../layui/js/angular.js"></script>
	<script type="text/javascript" src="../../layui/layui/GetPath.js"></script>
	<script src="../../layui/layui/layui.js" charset="utf-8"></script>
	<script type="text/javascript" src="../../layui/js/fy.js"></script>
	<script type="text/javascript" src="../../layui/layui/layer.ext.js"></script>
	<script type="text/javascript" src="../../layui/lay/modules/layer.js"></script>
	<script type="text/javascript" src="../../layui/layui.js"></script>
	<script>
		layui.use('form', function(){
			var form = layui.form();  
		});
	</script>
	<style type="text/css">     
    .mask {       
            position: absolute; top: 0px; filter: alpha(opacity=60); 
            z-index: 1002; left: 0px;              
			background:url(../../layui/layui/img/jz.gif) no-repeat center rgba(0,0,0,0.5) ;
		  	background-size:30px 30px;
			background-repeat: no-repeat;
			background: 
        }     
	</style>   
</head>
<body class="childrenBody">
<div align="center" id="mask" class="mask"></div>   
<blockquote class="layui-elem-quote news_search">
			<span style="width:80%;display:inline-block;  ">
				提取申请
			</span>
			<span>
				<a href="./tqList.html" class="layui-btn layui-btn-danger batchDel">返回我的提取</a>
			</span>
		</blockquote>
<form class="layui-form layui-form-pane">
	<div ng-app="myApp" ng-controller="customersCtrl">
		<div class="layui-form-item" pen>
			<label class="layui-form-label" style="width:140px;">提取人</label>
			<div class="layui-input-block">
				<input type="text" ng-model="xm" disabled class="layui-input" style="width:80%;">
			</div>
		</div>
		<div class="layui-form-item" pen>
			<label class="layui-form-label" style="width:140px;">证件号码</label>
			<div class="layui-input-block">
				<input type="text" ng-model="zjhm" id="zjhm" disabled class="layui-input" style="width:80%;">
			</div>
		</div>
		<div class="layui-form-item" pen>
			<label class="layui-form-label" style="width:140px;">单位名称</label>
			<div class="layui-input-block">
				<input type="text"  ng-model="dwmc" disabled class="layui-input" style="width:80%;">
			</div>
		</div>
		<div class="layui-form-item" pen>
			<label class="layui-form-label" style="width:140px;">单位账号</label>
			<div class="layui-input-block">
				<input type="text" ng-model="dwzh" disabled class="layui-input" style="width:80%;">
			</div>
		</div>
		<div class="layui-form-item" pen>
			<label class="layui-form-label" style="width:140px;">手机号码</label>
			<div class="layui-input-block">
				<input type="text" ng-model="sjhm" id="sjhm" disabled class="layui-input" style="width:80%;">
			</div>
		</div>
		<div class="layui-form-item" pen>
			<label class="layui-form-label" style="width:140px;">提取本金金额</label>
			<div class="layui-input-block">
				<input type="text" ng-model="bj" disabled class="layui-input" style="width:80%;">
			</div>
		</div>
		
		<div class="layui-form-item" pen>
			<label class="layui-form-label" style="width:140px;">提取利息金额</label>
			<div class="layui-input-block">
				<input type="text" ng-model="lx" disabled class="layui-input" style="width:80%;">
			</div>
		</div>
		<div class="layui-form-item" pen ng-hide="true">
			<label class="layui-form-label" style="width:140px;">停缴时间</label>
			<div class="layui-input-block">
				<input type="text" ng-model="tjrq" disabled class="layui-input" style="width:80%;">
			</div>
		</div>
		
		<div class="layui-form-item" pen>
			<label class="layui-form-label" style="width:140px;">提取本息合计</label>
			<div class="layui-input-block">
				<input type="text" ng-model="ye" disabled class="layui-input" style="width:80%;">
			</div>
		</div>
		<div class="layui-form-item" pen>
			<label class="layui-form-label" style="width:140px;">银行卡号</label>
			<div class="layui-input-block">
				<input type="text" ng-model="lmkh" id="yhkh" class="layui-input" style="width:80%;">
			</div>
		</div>
		<div class="layui-form-item" pen>
			<label class="layui-form-label" style="width:140px;">提取原因</label>
			<div class="layui-input-block" id="tq">
				<input type="radio" name="tqyy" value="退休" title="退休提取">
				<input type="radio" name="tqyy" value="离职" title="离职提取">
			</div>
		</div>
		
		<div class="layui-form-item" pen>
			<label class="layui-form-label" style="width:140px;">所属银行</label>
			<div class="layui-input-block" id="yh">
				<input type="radio" name="ssyh" value="602" title="建设银行">
				<input type="radio" name="ssyh" value="601" title="工商银行">
				<input type="radio" name="ssyh" value="603" title="农业银行">
				<input type="radio" name="ssyh" value="604" title="中国银行">
				<input type="radio" name="ssyh" value="605" title="交通银行">
				<input type="radio" name="ssyh" value="606" title="吉林银行">
			</div>
		</div>
		<div class="layui-form-item">
		    <div class="layui-inline">
		      <label class="layui-form-label" style="width:140px;">短信验证码</label>
		      <div class="layui-input-inline">
		        <input name="phone" ng-model="dxyz" id="dxyzm" lay-verify="required|phone" autocomplete="off" class="layui-input" type="tel">
		      </div>
		    </div>
		    <div class="layui-inline">
		      <div class="layui-input-inline">
		        <input type="button" class="layui-btn layui-btn-primary" onclick="settime(this);fs()"  value="发送验证码">
		      </div>
		    </div>
  		</div>
		

		<div class="layui-form-item">
			<div class="layui-input-block">
				<a class="layui-btn" ng-click="tj()">立即申请</a>
		    </div>
		</div>
	</div>
</form>
	<script type="text/javascript" src="../../layui/layui/layui.js"></script>
	<script>
		layui.use('form', function(){
			var layer = layui.layer;
		});
	</script>
	<script type="text/javascript" src="../../layui/layui/jquery-3.2.1.min.js"></script>
	<script type="text/javascript">
		function s(){     
        $("#mask").css("height",$(document).height());     
        $("#mask").css("width",$(document).width());     
        $("#mask").show();     
	    }  
	    //隐藏遮罩层  
	    function h(){     
	        $("#mask").hide();     
	    }  
	</script>
	<script src="../../layui/js/angular.js"></script>
	<script type="text/javascript">
		 var app = angular.module('myApp', []);
		 app.controller('customersCtrl', function($scope, $http) {
		 s();
			     $http({
					url : getPath() + "/wsyyt/txxhtqcontroller/test",
					contentType : "text/html;charset=utf-8",
					method : 'post',
				}).then(function(res) {
					h();
					if(res.data.msg==null){
								
								 	layer.msg("登陆失效请重新登陆");
									setTimeout(function () {
										window.top.location.href=res.data;
									}, 1500);
									return;
								 
					}else {
				     $scope.xm=res.data.data[0].XINGMING;
				     $scope.tjrq=res.data.data[0].TJSJ;
				     $scope.zjhm=res.data.data[0].ZJHM;
				     $scope.dwmc=res.data.data[0].DWMC;
				     $scope.dwzh=res.data.data[0].DWZH;
				     $scope.sjhm=res.data.data[0].DH;
				     $scope.ye=res.data.data[0].YE;
				     $scope.lx=res.data.data[0].LX;
				     $scope.bj=res.data.data[0].BJ;
				     }
				
	      /** 提交申请function */
			$scope.tj = function() {
			  var a=$("input[name='tqyy']:checked").val();
			  var b=$("input[name='ssyh']:checked").val();
			  var c=$("#yhkh").val();
			    var reg = /^[0-9]*$/;
      			var d= reg.test(c);
      			var e=$("#dxyzm").val();
			  if( a=="undefined" || a=="" || a==null ){
			  	//layer.msg('提取原因没有选中！',{icon: 5});
			  	layer.alert('提取原因没有选中！', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
				}});	
			  }else if(b=="undefined" || b==null||b==""){
			  	//layer.msg('所属银行没有选中！',{icon: 5});
			  	layer.alert('所属银行没有选中！', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
				}});
				}else if(c=="undefined" || c==null||c==""){
			  	//layer.msg('所属银行没有选中！',{icon: 5});
			  	layer.alert('银行卡号不能是空！', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
				}});	
				}else if(d==false){
			  	//layer.msg('所属银行没有选中！',{icon: 5});
			  	layer.alert('请输入正确的银行卡号！', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
				}});	
				}else if(e=="undefined" || e==null||e==""){
			  	//layer.msg('所属银行没有选中！',{icon: 5});
			  	layer.alert('请输入验证码！', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
				}});	
			  }else{
				$scope.params={
				   dqdm:res.data.data[0].DQDM,
				   grzh:res.data.data[0].V_个人账号,
				   dwzh:$scope.dwzh,
				   xhyy:a,
				   kh:$scope.lmkh,
				   bj:$scope.bj,
				   lx:$scope.lx,
				   ye:$scope.ye,
				   dxyz:$scope.dxyz,
				   tjsj:$scope.tjrq,
			       yh:b,
			       gsdqdm:res.data.data[0].GSDQDM,
			       ZJHM:$scope.zjhm,
			       SJHM:$("#sjhm").val()
				};
				s();
				$http({
					url : getPath() + "/wsyyt/txxhtqcontroller/test1",
					contentType : "text/html;charset=utf-8",
					method : 'post',
					params : $scope.params,
				}).then(function(res) {
					h();
				   $scope.code=res.data.code;
				   if(res.data.msg==null){
								
								 	layer.msg("登陆失效请重新登陆");
									setTimeout(function () {
										window.top.location.href=res.data;
									}, 1500);
									return;
								 
				   }else if($scope.code==0){
		   				//layer.msg('提示：申请成功,等待审核.....',{icon: 6});
		   				layer.alert('提示：该业务已办理成功，等待系统审核无误后资金，将于3个工作日内转入银行卡中', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 6    // icon
								     ,yes:function(){
									window.location.href='/wsyyt/page/gjj/tqList.html';
						}});	
					}else{
		  				//layer.msg('提示：'+res.data.CW,{icon: 5});
		  				layer.alert('提示：'+res.data.CW, {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								    ,btn2:function(){
							
						}});
					}
				});
			  };
			  };
			});
		});
	</script>
	<script>
		 function fs(){
        	  var a=$("#zjhm").val();
        	  var c=$("#sjhm").val();
            
        		  if(a=="" || a==null){
        			   //layer.alert("");
        			   layer.alert('提示：身份证不能为空！', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
						}});  
				 }else if(a.length!=18){ 
        			    layer.alert('提示：请输入正确的身份证号！', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
						}});  	
        		  }else if(c=="" || c==null){ 
        			    layer.alert('提示：预留手机号不能为空！', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
						}});  
        		  }else if(c.length!=11){  
        			    layer.alert('提示：请输入正确的手机号！', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 5    // icon
								     ,btn2:function(){
										
						}});  
        		   		  
        		  }else if(a!="" && c!=""  && c.length==11){
        		  		s();
						$.ajax({
							url : getPath()+'/wsyyt/zccontroller/grdx',
							method : 'post',
							dataType : 'JSON',
							data: {'sfzh':a,'sjhm':c},
							success : function(result) {
								h();
								var code = result.code;
								 if(code==0){
									 layer.alert('提示：发送成功', {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 6    // icon
								     ,btn2:function(){
										
									  }});	
								}else{		
								      layer.alert('提示：'+result.CW, {
								      skin: 'layui-layer-molv' //样式类名  自定义样式
								     ,closeBtn: 1    // 是否显示关闭按钮
								      ,anim: 1 //动画类型
								     ,btn: ['确认'] //按钮
								      ,icon: 6    // icon
								     ,btn2:function(){
										
									}});	
								}
							}
					});		
			};
	};
	</script>
	<script src="../../layui/jquery-3.2.1.min.js" charset="utf-8"></script>
	<script type="text/javascript"> 
			var countdown=60; 
			function settime(obj) { 
				 var a=$("#zjhm").val();
        	  	 var c=$("#sjhm").val();
        		    if(a=="" || a==null){
				    }else if(a.length!=18){ 
        		    }else if(c=="" || c==null){ 
        		    }else if(c.length!=11){  
        		    }else if(a!="" && c!=""  && c.length==11){
					    if (countdown == 0) { 
					        obj.removeAttribute("disabled");    
					        obj.value="发送短信验证码"; 
					        countdown = 60; 
					        return;
					    } else { 
					        obj.setAttribute("disabled", true); 
					        obj.value="重新发送(" + countdown + ")"; 
					        countdown--; 
					    } 
					    setTimeout(function() { 
					    settime(obj);}
					    ,1000);
				};
			
			};
	</script>
	<script type="text/javascript" src="../../js/log.js"></script>
</body>
</html>